from conans import ConanFile, CMake, tools
from conans import tools
import os
import sys
import os
sys.path.append(os.environ.get('PYTHONPATH'))
from pathlib import Path

class TestConan(ConanFile):
    name = "QssWraper"
    version = "1.1"
    license = "GPLV2"
    author = "zcy"
    url = "https://gitee.com/290198252/qsswraper"
    description = "qsswraper"
    settings = "os", "compiler", "build_type", "arch"

    def source(self):
        print("sys path is", sys.path)
        my_file = Path("./pkgsrc")
        if my_file.exists():
            print("not need to update source")
        else:
            print("source  cwd is", os.getcwd())
            git = tools.Git(folder="./pkgsrc", verify_ssl=False)
            git.clone(self.url)        

    def package(self):
        self.copy("*", dst="qsswraper", keep_path=True)


        
